/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 负差异文本 */
.text-danger {
    color: #EF4444;
}

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
}

/* 主题色变量 */
:root {
    --primary-color: #4F46E5;
    --secondary-color: #7C3AED;
    --accent-color: #EF4444;
    --success-color: #10B981;
    --warning-color: #EF4444;
    --background-color: #F9FAFB;
    --card-background: #FFFFFF;
    --text-primary: #111827;
    --text-secondary: #4B5563;
    --border-color: #E5E7EB;
}

/* 全局背景色 */
body {
    background-color: var(--background-color);
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 卡片阴影和圆角 */
.card-shadow {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    border-radius: 12px;
    transition: box-shadow 0.1s ease, transform 0.1s ease;
    backface-visibility: hidden;
}

.card-shadow:hover {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    transform: translateY(-1px);
}

/* 今日日程卡片 */
#today-schedule-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    position: relative;
    overflow: hidden;
    backface-visibility: hidden;
}

#today-schedule-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4F46E5, #7C3AED);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

#today-schedule-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    background-color: #f8fafc;
}

#today-schedule-card:hover::before {
    transform: scaleX(1);
}

/* 即将截止卡片 */
#upcoming-schedule-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    position: relative;
    overflow: hidden;
    backface-visibility: hidden;
}

#upcoming-schedule-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #EF4444, #F97316);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

#upcoming-schedule-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    background-color: #f8fafc;
}

#upcoming-schedule-card:hover::before {
    transform: scaleX(1);
}

/* 按钮样式 */
button {
    transition: all 0.2s ease;
    border-radius: 8px;
}

button:hover {
    transform: translateY(-1px);
}

button:active {
    transform: translateY(0);
}

/* 表单元素焦点 */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
    border-color: var(--primary-color);
}

/* 表单元素 */
input,
textarea,
select {
    transition: all 0.2s ease;
    border-radius: 8px;
    font-family: inherit;
}

input::placeholder,
textarea::placeholder {
    color: #9CA3AF;
}

/* 加载动画 */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-spinner {
    border: 3px solid rgba(79, 70, 229, 0.1);
    border-radius: 50%;
    border-top: 3px solid #4F46E5;
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
}

/* 加载屏幕 */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--background-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.loading-screen.fade-out {
    opacity: 0;
    transform: translateY(-20px);
    pointer-events: none;
}

/* 主内容过渡 */
.main-content {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease 0.2s, transform 0.8s ease 0.2s;
}

.main-content.fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* 加载动画容器 */
.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.big-loading-spinner {
    border: 5px solid rgba(79, 70, 229, 0.1);
    border-radius: 50%;
    border-top: 5px solid #4F46E5;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
}

.loading-text {
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--text-secondary);
}

@keyframes pulse-text {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

.loading-text-pulse {
    animation: pulse-text 1.5s ease-in-out infinite;
}

/* 响应式表格 */
@media (max-width: 640px) {
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
    
    .schedule-item {
        padding: 12px !important;
    }
}

/* 日程总览表格 */

/* 日历过渡 */
.calendar-fade-in {
    animation: fadeIn 0.3s ease-in-out forwards;
}

.calendar-fade-out {
    animation: fadeOut 0.3s ease-in-out forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* 日历容器固定高度 */
#calendar-body {
    min-height: 600px;
    transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out;
}
#schedule-list table,
.sticky.top-0 table {
    table-layout: fixed;
    width: 100%;
}

/* 表格列宽匹配 */
.sticky.top-0 th,
#schedule-list td {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 列宽设置 */
.sticky.top-0 th:nth-child(1),
#schedule-list td:nth-child(1) {
    width: 30%; /* 名称 */
}

.sticky.top-0 th:nth-child(2),
#schedule-list td:nth-child(2) {
    width: 20%; /* 时间 */
}

.sticky.top-0 th:nth-child(3),
#schedule-list td:nth-child(3) {
    width: 15%; /* 分类 */
}

.sticky.top-0 th:nth-child(4),
#schedule-list td:nth-child(4) {
    width: 15%; /* 状态 */
}

.sticky.top-0 th:nth-child(5),
#schedule-list td:nth-child(5) {
    width: 20%; /* 操作 */
    text-align: right;
}

/* 操作列右对齐 */
#schedule-list td:nth-child(5) .flex {
    justify-content: flex-end;
}

/* 日历单元格 */
.calendar-cell {
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
    /* 固定大小 */
    width: 100px;
    height: 120px;
    min-width: 100px;
    min-height: 120px;
    max-width: 100px;
    max-height: 120px;
    border-radius: 8px;
    overflow: hidden;
}

/* 日历表格列宽 */
#calendar-body td {
    width: 100px;
    height: 120px;
    vertical-align: top;
    padding: 4px;
}

/* 日历单元格内容 */
.calendar-cell > div {
    height: 100%;
    overflow-y: auto;
    /* 隐藏滚动条 */
    -ms-overflow-style: none;
    scrollbar-width: none;
    /* 平滑滚动 */
    scroll-behavior: smooth;
    border-radius: 6px;
    /* 优化渲染 */
    backface-visibility: hidden;
    will-change: contents;
}

/* 隐藏滚动条 */
.calendar-cell > div::-webkit-scrollbar {
    display: none;
}

/* 日程项悬浮效果 */
.schedule-item-hover {
    transition: transform 0.25s ease, background-color 0.25s ease;
    transform-origin: center left;
    position: relative;
    overflow: hidden;
    backface-visibility: hidden;
}

.schedule-item-hover:hover {
    transform: translateY(-3px);
    z-index: 20;
}

/* 日程项点击反馈 */
.schedule-item-hover:active {
    transform: translateY(-1px);
}


/* 已完成日程悬浮效果 */
.schedule-item-hover i.fa-check {
    transition: all 0.2s ease;
}

.schedule-item-hover:hover i.fa-check {
    color: #10B981;
    animation: checkBounce 0.3s ease;
}

@keyframes checkBounce {
    0%, 100% {
        /* 移除scale变换 */
        transform: none;
    }
    50% {
        /* 移除scale变换 */
        transform: none;
    }
}

.calendar-cell:hover {
    background-color: rgba(79, 70, 229, 0.1);
    z-index: 10;
    transform: translateY(-2px);
    backface-visibility: hidden;
}

.calendar-cell:active {
    transform: translateY(-1px);
}

/* 日期日程模态框 */
#day-schedule-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#day-schedule-modal.hidden {
    display: none;
}

#day-schedule-modal .modal-content {
    background-color: white;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
}

#day-schedule-modal .modal-header {
    padding: 20px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#day-schedule-modal .modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
}

#day-schedule-modal .modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

#day-schedule-modal .modal-footer {
    padding: 15px 20px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

#day-schedule-modal .schedule-item-hover {
    transition: background-color 0.2s;
}

#day-schedule-modal .schedule-item-hover:hover {
    background-color: #f9fafb;
}

.cursor-not-allowed {
    cursor: not-allowed !important;
    opacity: 0.6;
}

.cursor-not-allowed:hover {
    transform: none !important;
    box-shadow: none !important;
    background-color: #f9fafb !important;
    border-color: #e5e7eb !important;
}

/* 分类标签 */
.category-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.category-work {
    background-color: #dbeafe;
    color: #2563eb;
}

.category-study {
    background-color: #dcfce7;
    color: #16a34a;
}

.category-life {
    background-color: #fee2e2;
    color: #EF4444;
}

.category-health {
    background-color: #fef3c7;
    color: #d97706;
}

.category-other {
    background-color: #e5e7eb;
    color: #4b5563;
}

/* 响应式调整 */
@media (max-width: 640px) {
    #day-schedule-modal .modal-content {
        width: 100%;
        height: 100%;
        max-width: 100%;
        max-height: 100%;
        border-radius: 0;
    }
}


/* 日程提醒动画 */
@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

.reminder-pulse {
    animation: pulse 2s infinite;
}

/* 日程状态标签 */
.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-pending {
    background-color: #FEF3C7;
    color: #92400E;
}

.status-completed {
    background-color: #D1FAE5;
    color: #065F46;
}

.status-overdue {
    background-color: #FEE2E2;
    color: #991B1B;
}

/* 工具提示 */
.tooltip {
    position: relative;
    display: inline-block;
    z-index: 1000;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 120px;
    background-color: #111827;
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 6px 8px;
    position: absolute;
    z-index: 1001;
    bottom: 130%;
    left: 50%;
    margin-left: -60px;
    opacity: 0;
    transform: translateY(5px);
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    font-size: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

/* 操作按钮悬浮效果 */
.edit-schedule-btn, .edit-today-schedule-btn, .edit-upcoming-schedule-btn, .edit-category-schedule-btn,
.complete-schedule-btn, .complete-today-schedule-btn, .complete-upcoming-schedule-btn, .complete-category-schedule-btn,
.undo-schedule-btn, .undo-day-schedule-btn,
.delete-schedule-btn, .delete-today-schedule-btn, .delete-upcoming-schedule-btn, .delete-category-schedule-btn, .delete-day-schedule-btn {
    position: relative;
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
    border: none;
    margin: 0 2px;
    padding: 0;
}

.edit-schedule-btn:hover, .edit-today-schedule-btn:hover, .edit-upcoming-schedule-btn:hover, .edit-category-schedule-btn:hover {
    background-color: rgba(79, 70, 229, 0.1);
    color: #4F46E5;
}

.complete-schedule-btn:hover, .complete-today-schedule-btn:hover, .complete-upcoming-schedule-btn:hover, .complete-category-schedule-btn:hover {
    background-color: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.undo-schedule-btn:hover, .undo-day-schedule-btn:hover {
    background-color: rgba(245, 158, 11, 0.1);
    color: #F59E0B;
}

.delete-schedule-btn:hover, .delete-today-schedule-btn:hover, .delete-upcoming-schedule-btn:hover, .delete-category-schedule-btn:hover, .delete-day-schedule-btn:hover {
    background-color: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

/* 图标缩放 */
.edit-schedule-btn i, .edit-today-schedule-btn i, .edit-upcoming-schedule-btn i, .edit-category-schedule-btn i,
.complete-schedule-btn i, .complete-today-schedule-btn i, .complete-upcoming-schedule-btn i, .complete-category-schedule-btn i,
.undo-schedule-btn i, .undo-day-schedule-btn i,
.delete-schedule-btn i, .delete-today-schedule-btn i, .delete-upcoming-schedule-btn i, .delete-category-schedule-btn i, .delete-day-schedule-btn i {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.edit-schedule-btn:hover i, .edit-today-schedule-btn:hover i, .edit-upcoming-schedule-btn:hover i, .edit-category-schedule-btn:hover i,
.complete-schedule-btn:hover i, .complete-today-schedule-btn:hover i, .complete-upcoming-schedule-btn:hover i, .complete-category-schedule-btn:hover i,
.undo-schedule-btn:hover i, .undo-day-schedule-btn:hover i,
.delete-schedule-btn:hover i, .delete-today-schedule-btn:hover i, .delete-upcoming-schedule-btn:hover i, .delete-category-schedule-btn:hover i, .delete-day-schedule-btn:hover i {
    transform: scale(1.2);
}

/* 按钮层级 */
.edit-schedule-btn, .complete-schedule-btn, .undo-schedule-btn, .delete-schedule-btn {
    z-index: 9999;
}

/* 隐藏按钮提示 */
.edit-schedule-btn .tooltiptext,
.edit-today-schedule-btn .tooltiptext,
.edit-upcoming-schedule-btn .tooltiptext,
.edit-category-schedule-btn .tooltiptext,
.complete-schedule-btn .tooltiptext,
.complete-today-schedule-btn .tooltiptext,
.complete-upcoming-schedule-btn .tooltiptext,
.complete-category-schedule-btn .tooltiptext,
.undo-schedule-btn .tooltiptext,
.undo-day-schedule-btn .tooltiptext,
.delete-schedule-btn .tooltiptext,
.delete-today-schedule-btn .tooltiptext,
.delete-upcoming-schedule-btn .tooltiptext,
.delete-category-schedule-btn .tooltiptext,
.delete-day-schedule-btn .tooltiptext {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 4rem 1rem;
}

.empty-state-icon {
    font-size: 4rem;
    color: #D1D5DB;
    margin-bottom: 1rem;
}

.empty-state-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #6B7280;
    margin-bottom: 0.5rem;
}

.empty-state-description {
    color: #9CA3AF;
    font-size: 0.875rem;
}

/* 日程项过渡 */
.schedule-item {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.schedule-item.active {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.schedule-item-exit {
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity 0.2s ease-in-out, transform 0.2s ease-in-out;
}

/* 进入动画 */
.schedule-item-enter {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.schedule-item-enter.appear {
    opacity: 1;
    transform: translateY(0);
}

/* 列表容器过渡 */
.schedule-list-container {
    min-height: 100px;
    position: relative;
    overflow: hidden;
}

/* 分类弹窗列表容器 */
#category-schedule-list {
    min-height: 100px;
    position: relative;
    overflow: hidden;
}

/* 日程卡片 */
.schedule-card {
    border-radius: 0.75rem;
    background-color: #FFFFFF;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    padding: 1rem;
    margin-bottom: 1rem;
    transition: all 0.2s ease;
}

.schedule-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transform: translateY(-1px);
}

/* 分类标签 */
.category-tag {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    margin-right: 0.5rem;
}

.category-work {
    background-color: #EEF2FF;
    color: #4F46E5;
}

.category-study {
    background-color: #F5F3FF;
    color: #7C3AED;
}

.category-life {
    background-color: #fee2e2;
    color: #EF4444;
}

.category-health {
    background-color: #D1FAE5;
    color: #10B981;
}

.category-other {
    background-color: #F3F4F6;
    color: #6B7280;
}

/* 日程分类按钮 */
.category-btn {
    position: relative;
    overflow: hidden;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.category-btn:hover {
    background-color: rgba(79, 70, 229, 0.05);
    border-color: rgba(79, 70, 229, 0.2);
}

.category-btn:active {
    transform: translateX(2px);
}

/* 添加日程按钮 */
#add-schedule-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

#add-schedule-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

#add-schedule-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px -5px rgba(79, 70, 229, 0.4), 0 8px 10px -6px rgba(79, 70, 229, 0.2);
    background-color: #4338CA; /* 稍深的主色 */
}

#add-schedule-btn:hover::before {
    left: 100%;
}

#add-schedule-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 10px -5px rgba(79, 70, 229, 0.4);
}

/* 按钮图标动画 */
#add-schedule-btn i {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#add-schedule-btn:hover i {
    transform: rotate(45deg);
}

#add-schedule-btn:active i {
    transform: rotate(45deg);
}

/* 分类按钮图标 */
.category-btn .rounded-full {
    width: 12px;
    height: 12px;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5);
}

/* 分类弹窗过滤按钮 */
.category-filter-buttons button, 
#category-schedule-modal button[id^="category-status-"],
#category-schedule-modal button[id^="category-range-"] {
    padding: 8px 16px;
    border: 1px solid #e5e7eb;
    background: white;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #4b5563;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.category-filter-buttons button:hover,
#category-schedule-modal button[id^="category-status-"]:hover,
#category-schedule-modal button[id^="category-range-"]:hover {
    background: #f9fafb;
    border-color: #d1d5db;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.category-filter-buttons button.active,
#category-schedule-modal button[id^="category-status-"].text-primary,
#category-schedule-modal button[id^="category-range-"].text-primary {
    background: linear-gradient(135deg, var(--primary-color), #4338ca);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.3);
}

/* 确认对话框 */
#confirm-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    transition: opacity 0.3s ease;
}

.confirm-dialog-content {
    background-color: #FFFFFF;
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 90%;
    width: 28rem;
    animation: dialogSlideIn 0.3s ease-out;
}

/* 日期日程模态框 */
#day-schedule-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#day-schedule-modal.hidden {
    display: none;
}

#day-schedule-modal .modal-content {
    background-color: white;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
}

#day-schedule-modal .modal-header {
    padding: 20px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#day-schedule-modal .modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
}

#day-schedule-modal .modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

#day-schedule-modal .modal-footer {
    padding: 15px 20px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

#day-schedule-modal .schedule-item-hover {
    transition: background-color 0.2s;
}

#day-schedule-modal .schedule-item-hover:hover {
    background-color: #f9fafb;
}

.category-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.category-work {
    background-color: #dbeafe;
    color: #2563eb;
}

.category-study {
    background-color: #dcfce7;
    color: #16a34a;
}

.category-life {
    background-color: #fee2e2;
    color: #EF4444;
}

.category-health {
    background-color: #fef3c7;
    color: #d97706;
}

.category-other {
    background-color: #e5e7eb;
    color: #4b5563;
}

.cursor-not-allowed {
    cursor: not-allowed !important;
    opacity: 0.6;
}

/* 响应式调整 */
@media (max-width: 640px) {
    #day-schedule-modal .modal-content {
        width: 100%;
        height: 100%;
        max-width: 100%;
        max-height: 100%;
        border-radius: 0;
    }
}

@keyframes dialogSlideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.confirm-dialog-header {
    margin-bottom: 1rem;
}

#confirm-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1F2937;
    margin-bottom: 0.5rem;
}

#confirm-message {
    color: #4B5563;
    margin-bottom: 1.5rem;
}

.confirm-dialog-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

.confirm-dialog-button {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

#confirm-cancel {
    background-color: #F3F4F6;
    color: #4B5563;
}

#confirm-cancel:hover {
    background-color: #E5E7EB;
}

#confirm-ok {
    background-color: #EF4444;
    color: #FFFFFF;
}

#confirm-ok:hover {
    background-color: #DC2626;
}

.hidden {
    display: none !important;
}

/* 通知样式 */
.notification {
    position: fixed;
    top: 2rem;
    right: 2rem;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    z-index: 50;
    animation: slideIn 0.3s ease-out;
}

/* 通知图标 */
.notification-icon:hover {
    /* 移除scale变换 */
    color: #4F46E5;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.notification-success {
    background-color: #D1FAE5;
    color: #065F46;
    border-left: 4px solid #10B981;
}

.notification-error {
    background-color: #FEE2E2;
    color: #991B1B;
    border-left: 4px solid #EF4444;
}

.notification-warning {
    background-color: #FEF3C7;
    color: #92400E;
    border-left: 4px solid #F59E0B;
}

/* 确认对话框样式 */
.confirm-dialog {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #FFFFFF;
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    z-index: 50;
    max-width: 90%;
    width: 28rem;
}

/* 分类日程弹窗 */
#category-schedule-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    overflow-y: auto;
}

.category-schedule-modal-content {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.category-modal-header {
    padding: 20px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.category-modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    color: #333;
}

.category-modal-body {
    padding: 20px;
    flex: 1;
    overflow-y: auto;
}

/* 弹窗筛选器 */
.category-filter-container {
    margin-bottom: 20px;
}

.category-filter-section {
    margin-bottom: 15px;
}

.category-filter-section h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: #666;
    margin-bottom: 8px;
}

.category-filter-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.category-filter-buttons button {
    padding: 6px 12px;
    border: 1px solid #e0e0e0;
    background: white;
    border-radius: 20px;
    font-size: 0.875rem;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}

.category-filter-buttons button:hover {
    background: #f9f9f9;
}

.category-search-box {
    margin-bottom: 20px;
}

.category-search-box input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 0.875rem;
    outline: none;
    transition: border-color 0.2s;
}

.category-search-box input:focus {
    border-color: #4299e1;
}

/* 分类日程列表 */
#category-schedule-list {
    max-height: calc(70vh - 120px);
    overflow-y: auto;
    padding-bottom: 20px; /* 底部内边距 */
}

.category-schedule-item {
    transition: all 0.2s;
}

.category-schedule-item:hover {
    background-color: #f9fafb;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .category-schedule-modal-content {
        width: 95%;
        max-width: none;
        margin: 20px;
    }
    
    .category-modal-body {
        padding: 15px;
    }
    
    .category-filter-buttons {
        gap: 6px;
    }
    
    .category-filter-buttons button {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
}

/* 日期选择器 */
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
    filter: invert(50%);
}

/* 按钮焦点状态 */
button:focus {
    outline: 2px solid rgba(79, 70, 229, 0.5);
    outline-offset: 2px;
}

/* 打印样式 */
@media print {
    header,
    footer,
    button,
    .modal {
        display: none !important;
    }
    
    body {
        background-color: white;
    }
    
    .container {
        width: 100%;
        max-width: 100%;
        padding: 0;
    }
}

/* 高对比度模式 */
@media (prefers-contrast: high) {
    .border-gray-200 {
        border-color: #000000;
    }
    
    button,
    input,
    textarea,
    select {
        border-width: 2px;
    }
}